@layout("/common/_container.html"){
<div class="row">
    <div class="col-sm-12">
        <div class="ibox float-e-margins">
            <div class="ibox-title">
                <h5>系统附件管理</h5>
            </div>
            <div class="ibox-content">
                <div class="row row-lg">
                    <div class="col-sm-12">
                        <div class="row">
                            <div class="col-sm-3">
                                <#NameCon id="condition" name="名称" />
                            </div>
                            <div class="col-sm-3">
                                <#SelectCon id="saveToCondition" name="保存方式" >
                                <option  value="">全部</option>
                                <option  value="db">DB</option>
                                <option value="s3">S3</option>
                                <option value="filesystem">FILESYSTEM</option>
                                </#SelectCon>
                            </div>
                            <div class="col-sm-3">
                                <#button name="搜索" icon="fa-search" clickFun="Attachment.search()"/>
                            </div>
                        </div>
                        <div class="hidden-xs" id="AttachmentTableToolbar" role="group">
                            @if(shiro.hasPermission("/attachment/add")){
                                <#button name="添加" icon="fa-plus" clickFun="Attachment.openAddAttachment()"/>
                            @}
                            @if(shiro.hasPermission("/attachment/update")){
                                <#button name="修改" icon="fa-edit" clickFun="Attachment.openAttachmentDetail()" space="true"/>
                            @}
                            @if(shiro.hasPermission("/attachment/delete")){
                                <#button name="删除" icon="fa-minus" clickFun="Attachment.delete()" space="true"/>
                            @}
                            @if(shiro.hasPermission("/attachment/update")){
                                <div class="dropdown" style="display: inline-block;">
								  <button class="btn btn-primary button-margin dropdown-toggle" type="button" id="dropdownMenu1"
								     data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
								   	 <i class="fa fa-exchange"></i>&nbsp;移动
								    <span class="caret"></span>
								  </button>
								  <ul class="dropdown-menu" aria-labelledby="dropdownMenu1">
								    <li><a href="#" onclick="Attachment.moveAttachment('S3')">S3</a></li>
								    <li><a href="#" onclick="Attachment.moveAttachment('FILESYSTEM')">FileSystem</a></li>
								    <li><a href="#" onclick="Attachment.moveAttachment('DB')">Db</a></li>
								  </ul>
								</div>
                            @}
                        </div>
                        <#table id="AttachmentTable"/>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="${ctxPath}/static/modular/system/attachment/attachment.js"></script>
@}
